Currenty, network devices may need to obtain a media access control (MAC) address of a destination device before they can communicate with each other. ARP may be used to obtain the MAC address. ARP is able to transform an Internet protocol (IP) address into a corresponding MAC address. ARP functions to query the MAC address of the destination device according to the IP address. However, ARP is easy to be attacked, hackers may send fake ARP response packets to cheat other users, thus influence the normal communication in network.